cmake_minimum_required(VERSION 3.10)

# 项目基本信息
project(MultiMotor VERSION 1.0 LANGUAGES CXX)

# 设置C++标准
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED True)

# 设置头文件和库的搜索路径
include_directories(
  include
)
link_directories(
  lib
)

# 设置编译标志
add_definitions(-std=c++14)

# 添加源文件
set(SOURCE_FILES
    src/main.cpp
)

# 添加可执行文件
add_executable(multi_motor ${SOURCE_FILES})

# 链接所需的库
target_link_libraries(multi_motor
    PRIVATE
    mylibti5_multi_motor
    mylibscan
    controlcan
)

# 输出编译信息
message(STATUS "Building project MultiMotor version ${MultiMotor_VERSION}")